package com.leiyk.rateLimiter.annotation;

import java.lang.annotation.*;
import java.util.concurrent.TimeUnit;

/**
 * @Description: 限流注解
 * @Author: leiyk6
 * @Date: 2024/7/2 17:14
 */
@Target(ElementType.METHOD)
@Documented
@Retention(RetentionPolicy.RUNTIME)
public @interface SimpleRateLimiter {
    int time(); // 时间，单位为秒

    int maxCount();

    String msg() default "请求过多，稍后重试";

}
